package com.headfirst.CreateMode.factory.simplefactory;

/**
 * 当你想吃披萨时，就找这家披萨店，并把你想吃的披萨口味告诉它，然后披萨店就会委托简单工厂给你做出一个美味可口的披萨啦
 * @author sunhongguang
 * @create 2022-01-23-18:53
 */
public class PizzaStore {
    
    public Pizza orderPizza(String type){
        Pizza pizza;
        pizza = SimplePizzaFactory.createPizza(type);
        pizza.prepare();
        pizza.bake();
        pizza.cut();
        pizza.box();
        return pizza;
    }
}
